<?php

	global $file,$Drafts;

	css_include('fmgr.css');
	$Drafts = $this->fmgr->open('temp:/drafts');
	$file = $this->file;
	
	js_include('Fmgr.js?file');
	js_include_shared('codepress/codepress.js');

	$Tlb = Toolbar();
	$Tlb->option('File')->option('Save')->toFunction('File.save();', 'File.write;');
	$Tlb->option('File')->option('Save As...')->toFunction('File.saveAs();');
	$Tlb->option('File')->option('Nice Name')->toFunction('Namer.begin();', '!is_null(window.O_ID)');
	$Tlb->option('File')->option('Link Here')->toFunction('Smajax.exec("newlink")');
	
	$Tlb->option('View')->option('File Contents')->toFunction('View.switchTo(0);', 'View.cur != 0;');
	$Tlb->option('View')->option('Resource Data')->toFunction('View.switchTo(1);', 'View.cur != 1;');
	$Tlb->option('View')->option('Meta Data')->toFunction('View.switchTo(2);', 'View.cur != 2;');
	$Tlb->option('View')->option('Shortcuts')->toFunction('showKeyboard()');
	
?>